package com.douglas.managesystem.service.system.impl;


import com.douglas.managesystem.common.FileConfiguration;
import com.douglas.managesystem.dao.SystemMapper;
import com.douglas.managesystem.entity.SystemConfig;
import com.douglas.managesystem.service.system.SystemService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * 系统设置业务处理类
 * 
 * @author LIGW
 */
@Service
public class SystemServiceImpl implements SystemService {

	/**
	 * 日志输出
	 */
//	private static final Logger logger = LoggerUtils.getLogger(SystemServiceImpl.class);
	@Autowired
	private SystemMapper systemMapper;
	@Autowired
	private FileConfiguration fileConfiguration;

	/**
	 * 系统设置列表
	 */
	@Override
	public SystemConfig getSystem() {
		SystemConfig SystemConfig = systemMapper.selectAll();
		return SystemConfig;
	}

	/**
	 * 更新系统设置
	 */
	@Override
	public int update(SystemConfig systemConfig) {
		int num = systemMapper.updateByPrimaryKey(systemConfig);
		return num;
	}

}
